const fs = require('fs');
// const path = require('path');
const {resolve:r} = require('path');
const {resolve:r2} = require('path');
const {resolve:r3} = require('path');

// let res = fs.statSync(__dirname+'/a');

// let res = fs.statSync(path.resolve(__dirname,'./2.html'));

let res = fs.statSync(r(__dirname,'./2.html'))

console.log(res.isFile());
console.log(res.isDirectory());